<%@page import="util.DomainUtils"%>
<%@ taglib prefix="html" uri="http://struts.apache.org/tags-html"%>
<%@ taglib prefix="bean" uri="http://struts.apache.org/tags-bean"%>
<%@ taglib prefix="nested" uri="http://struts.apache.org/tags-nested"%>
<div class="container">
	<div class="navbar navbar-inverse navbar-static-top">
		<div class="top-navbar-div" style="float: left; margin-left: 5px;">
			<div class="btn-group">
				<a class="btn btn-default navbar-btn" href="pages/index.jsp">Home</a>
				<%
					if (request.getSession(false).getAttribute(
							DomainUtils.CURRENT_USER_STRING) == null) {
						out.print("");
					} else {%>
						<a class="btn btn-default navbar-btn" href="pages/addContact.jsp">Add contact</a>
						<a class="btn btn-default navbar-btn" href="pages/showAllContact.jsp">Show contacts</a>
						<a class="btn btn-default navbar-btn" href="pages/addContactGroup.jsp">Add contact group</a>
						<a class="btn btn-default navbar-btn" href="pages/showAllContactGroups.jsp">Show contact groups</a>
						<html:form action="/Disconnect">
						<button type="submit" class="btn btn-default navbar-btn">Disconnect</button>
						</html:form>
					<%}%>
			</div>
		</div>
		<div style="float: right;">
			<p style="text-align: center;">
				<%=(request.getSession(false).getAttribute(
					DomainUtils.CURRENT_USER_STRING) == null) ? "<span style=\"padding-right: 20px; color: white;\"> Not yet registered ? </span>"
					+ "<br />"
					+ "<span style=\"padding-right: 20px;\">"
					+ "<a href=\"/mdoc-project/pages/register.jsp\">Register</a>"
					+ "</span>"
					: ""%>
			</p>
		</div>
	</div>